<template>
  <div>
    <common-table v-if="pageData.viewMode==='list'" />
    <hd-form v-else-if="pageData.viewMode==='info'" />
  </div>
</template>
<script>
import CommonTable from "@/components/TkCommonPage/components/CommonTable.vue"
import HdForm from "@/components/TkCommonPage/components/HdForm.vue"

export default {
  name: "HdPage",
  components: { HdForm, CommonTable },
  inject: ["pageData"],
  methods: {
    /**
     * 更新主表数据
     * @param key
     * @param value
     */
    updateHForm(key, value) {
      this.$set(this.pageData.formData.head, key, value)
    }
  }
}
</script>

<style scoped lang="scss">

</style>
